package com.googlecode.jasmincc.framework.services.implementation;

import java.io.File;

import com.googlecode.jasmincc.framework.services.GetGrammarNameByFile;

public class SimpleGetGrammarNameByFile implements GetGrammarNameByFile {

	public String getName(File file) {
		String fileName = file.getName();
		int dot = fileName.lastIndexOf('.');
		String grammarName = fileName.substring(0, dot);
		return grammarName;
	}

}
